package com.ykt.service;

import com.ykt.model.ClientVersion;

import java.util.List;

/**
 * 客户端版本服务
 * @author long.hua
 * @version 1.0.0
 * @since 2016-02-15 23:27
 */
public class ClientVersionService {

    private ClientVersion versionDao = ClientVersion.dao;


    // 根据版本号查询商铺客户最新版本
    public ClientVersion findByVersionCode(int versionCode, int type){
        List<ClientVersion> list = versionDao.findByVersionCode(versionCode, type);
        if(list != null && !list.isEmpty()){
            return list.get(0);
        }

        return null;
    }

}
